from django.db import models


class EntrustBill:
    def __init__(self, report_num, sample_num, entrust_num, test_item_name, test_item_parm_name, project_num, project_name, entrust_unit_name, send_sample_man, entrust_date, sizes, conclusion, need_charge_money):
        self.ReportNum = report_num
        self.SampleNum = sample_num
        self.EntrustNum = entrust_num
        self.TestItemName = test_item_name
        self.TestItemParmName = test_item_parm_name
        self.ProjectNum = project_num
        self.ProjectName = project_name
        self.EntrustUnitName = entrust_unit_name
        self.SendSampleMan = send_sample_man
        self.EntrustDate = entrust_date
        self.Sizes = sizes
        self.Conclusion = conclusion
        self.NeedChargeMoney = need_charge_money

    def __str__(self):
        return f"{self.ReportNum} {self.ProjectName}"



class Testitems(models.Model):
    Name = models.CharField(null=True, blank=True, max_length=100)
    Code = models.CharField(null=True, blank=True, max_length=100)

    def __str__(self) -> str:
        return super().__str__()
